package com.wst.system.server.service;

import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wst.system.config.exception.GlobalExcetion;
import com.wst.system.security.entity.SysMenuEntity;
import com.wst.system.security.entity.dto.SysMenuEntityListDto;
import com.wst.system.security.entity.dto.SysMenuEntityTreeDto;
import com.wst.system.security.entity.dto.SysMenuEntityTreeMenuDto;
import com.wst.system.security.entity.vo.SysMenuEntityVo;

import java.util.List;

/**
 * @author Xiongx
 * @version 1.0
 * @date 2021/6/11 14:45
 * @since JDK 1.8
 */
public interface SysMenuService extends IService<SysMenuEntity> {

    public SysMenuEntity saveOrUpdate(SysMenuEntityVo sysMenuEntityVo) throws GlobalExcetion;

    public SysMenuEntity getSysMenuEntityByParentId(Integer parentId);

    public IPage<SysMenuEntity> page(Integer pageNum, Integer pageSize, JSONObject search);

    public List<SysMenuEntityTreeDto> childList();

    public List<SysMenuEntityTreeMenuDto> childMenuList(List<SysMenuEntity> list);

    public List<SysMenuEntityListDto> listAll();

    public List<SysMenuEntityTreeDto> childList(String name);

    public List<SysMenuEntityTreeDto> childList(List<Integer> childList);

    public List<SysMenuEntityTreeMenuDto> childMenuListByCid(List<Integer> childList);
}
